package com.ego.ware.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.ego.common.constant.WareConstant;
import org.springframework.stereotype.Service;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;

import com.ego.ware.dao.WareOrderTaskDetailDao;
import com.ego.ware.po.WareOrderTaskDetail;
import com.ego.ware.service.WareOrderTaskDetailService;

import java.util.List;

/**
 * @author KamTang
 * @program: ego
 * @description 库存工作单对应实现类
 * @date 2022-11-13 13:30:29
 */
@Service("wareOrderTaskDetailService")
public class WareOrderTaskDetailServiceImpl extends ServiceImpl<WareOrderTaskDetailDao, WareOrderTaskDetail> implements WareOrderTaskDetailService {
    @Override
    public List<WareOrderTaskDetail> getLocked(Long id) {
        return this.list(new QueryWrapper<WareOrderTaskDetail>().eq("task_id", id)
                .eq("lock_status", WareConstant.WareOrderTaskLockStatusEnum.LOCKED));
    }
}
